package cn.lanqiao.springboot.entity;

import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Pattern;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
/**
 * (SystemUser)实体类
 *
 * @author david
 * @since 2025-09-10 09:40:44
 */
@Data
public class User implements Serializable {
    private static final long serialVersionUID = 210915233215621449L;

    private Integer userId;

    @NotNull(message = "用户名不能为空")
    @Pattern(regexp = "^[a-zA-Z0-9_]{3,16}$", message = "用户名必须是3到16位的字母、数字或下划线")
    private String userName;

    @NotNull(message = "密码不能为空")
    private String password;

//    @NotNull(message = "邮箱不能为空")
    private String email;

    private String facePic;

    private Date createTime;

    private String phone;

    private Integer isLocked;

}
